home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacOS 8 Resources / Developer Tools / Mac OS 8 Interfaces & Libraries / Interfaces / CIncludes / NuBus.h < prev    next >
C/C++ Source or Header  |  1996-05-01  |  2KB  |  120 lines

  1. /*
  2.      File:        NuBus.h
  3.  
  4.      Contains:    NuBus I/O Interfaces 
  5.  
  6.      Version:    Technology:    xxx Put version info here xxx
  7.                  Release:    Universal Interfaces 3.0d3 on Copland DR1
  8.  
  9.      Copyright:    © 1984-1996 by Apple Computer, Inc.  All rights reserved.
  10.  
  11.      Bugs?:        If you find a problem with this file, send the file and version
  12.                  information (from above) and the problem description to:
  13.  
  14.                      Internet:    apple.bugs@applelink.apple.com
  15.                      AppleLink:    APPLE.BUGS
  16.  
  17. */
  18. #ifndef __NUBUS__
  19. #define __NUBUS__
  20.  
  21. #ifndef __TYPES__
  22. #include <Types.h>
  23. #endif
  24. #ifndef __SLOTS__
  25. #include <Slots.h>
  26. #endif
  27.  
  28. #ifdef __cplusplus
  29. extern "C" {
  30. #endif
  31.  
  32. #if PRAGMA_IMPORT_SUPPORTED
  33. #pragma import on
  34. #endif
  35.  
  36. #if PRAGMA_ALIGN_SUPPORTED
  37. #pragma options align=mac68k
  38. #endif
  39.  
  40. #if FOR_SYSTEM8_PREEMPTIVE
  41. /*
  42.  *
  43.  * kSpaceCode -
  44.  *
  45.  * Bitfield definitions for the "reg" and "assigned-adderesses"
  46.  * properties found in the device portion of the NameRegistry
  47.  *
  48. */
  49.  
  50. enum {
  51.     kSpaceCodeMask                = 0x03000000,
  52.     kSpaceCodeMem64                = 0x03000000,
  53.     kSpaceCodeMem32                = 0x02000000,
  54.     kSpaceCodeIO                = 0x01000000,
  55.     kSpaceCodeConfig            = 0x00000000,
  56.     kDeviceCodeMask                = 0x000000FF
  57. };
  58.  
  59. typedef UInt32 EncodeInt;
  60. struct EncodePhys {
  61.     EncodeInt                         hi;
  62.     EncodeInt                         mid;
  63.     EncodeInt                         lo;
  64. };
  65. typedef struct EncodePhys EncodePhys;
  66.  
  67. struct EncodeSize {
  68.     EncodeInt                         hi;
  69.     EncodeInt                         lo;
  70. };
  71. typedef struct EncodeSize EncodeSize;
  72.  
  73. /*
  74.  * PropertyReg & PropertyAssignedAddresses -
  75.  *
  76.  * The struct format definitions for the "reg" and
  77.  * "assigned-addresses" NameRegistry properties.
  78.  *
  79. */
  80. struct PropertyReg {
  81.     EncodePhys                         phys;
  82.     EncodeSize                         size;
  83. };
  84. typedef struct PropertyReg PropertyReg;
  85.  
  86. struct MotherboardReg {
  87.     EncodeInt                         base;
  88.     EncodeInt                         length;
  89. };
  90. typedef struct MotherboardReg MotherboardReg;
  91.  
  92. /*
  93.  * Family service category and name declarations
  94.  * (that's it for now)
  95.  *
  96. */
  97.  
  98. enum {
  99.     kServiceCategoryNuBus        = 'nbus'
  100. };
  101.  
  102. #define kFamilyNameNuBus    "\pNuBus" 
  103.  
  104. #endif
  105.  
  106. #if PRAGMA_ALIGN_SUPPORTED
  107. #pragma options align=reset
  108. #endif
  109.  
  110. #if PRAGMA_IMPORT_SUPPORTED
  111. #pragma import off
  112. #endif
  113.  
  114. #ifdef __cplusplus
  115. }
  116. #endif
  117.  
  118. #endif /* __NUBUS__ */
  119.  
  120.